home *** CD-ROM | disk | FTP | other *** search
Text File | 1994-12-05 | 1.1 KB | 53 lines | [TEXT/MPS ] |
- /*
- File: mtb6.c
- Contains: Movie Creation Functions
- Written by: DTS and QT Engineering
- Copyright: © 1992-1994 by Apple Computer, Inc., all rights reserved.
- Change History (most recent first):
- <1> 12/4/94 khs changed the format of the file to the new look and feel
- To Do:
- */
-
-
- // INCLUDE FILES
- #include "mtb.h"
-
-
- // FUNCTIONS
- void CreateMyCoolMovie(void)
- {
- Point where =
- {
- 100, 100
- }
- ;
-
- SFReply theSFReply;
- Movie theMovie = nil;
- FSSpec mySpec;
- short resRefNum = 0;
- short resId = 0;
- OSErr err = noErr;
-
- SFPutFile(where, "\pEnter movie file name:", "\pMovie File", nil, &theSFReply);
- if (!theSFReply.good)
- return;
-
- FSMakeFSSpec(theSFReply.vRefNum, 0, theSFReply.fName, &mySpec);
-
- err = CreateMovieFile(&mySpec, 'TVOD', smCurrentScript, createMovieFileDeleteCurFile, &resRefNum, &theMovie);
- CheckError(err, "\pCreateMovieFile");
-
- CreateMyVideoTrack(theMovie);
- CreateMySoundTrack(theMovie);
-
- err = AddMovieResource(theMovie, resRefNum, &resId, theSFReply.fName);
- CheckError(err, "\pAddMovieResource");
-
- if (resRefNum)
- CloseMovieFile(resRefNum);
- DisposeMovie(theMovie);
- }
-
-
-